import { defineStore } from 'pinia'
import { ref } from 'vue'
import routes from '@/router/routes'

export const useLayoutStore = defineStore('layout', () => {

  const menuRoutes = routes
  // 定义全局可使用的属性（跨组件共享属性）
  // - 菜单折叠
  const fold = ref(false)
  // - 刷新
  const refresh = ref(false)

  return {
    menuRoutes,
    fold,
    refresh
  }
})
